package taskOnClasses;

public class Person {
	private String Name;
	private String Surname;
	private int Age;
	private int DateOfBirth;
	private Gender Gender;

    public int getDateOfBirth() {
        return DateOfBirth;
    }

    public int getAge() {
        return Age;
    }

    public void setDateOfBirth(int DateOfBirth) {
        this.DateOfBirth = DateOfBirth;
    }

    public String getName() {
        return Name;
    }

    public void setName(String Name) {
        this.Name = Name;
    }

    public void setNewSurname(String newName){
        this.Surname = newName;
    }
	
	public Person(String someName, String someSurname, int someAge, int someDOB, String someG){
		if(someG.equalsIgnoreCase("male")){
			this.Gender = Gender.MALE;
		}
		else if (someG.equalsIgnoreCase("female")){
			this.Gender = Gender.FEMALE;
		}
		this.Name = someName;
		this.Surname = someSurname;
		this.Age = someAge;
		this.DateOfBirth = someDOB;
		//this.Gender = someG;
	}
	public void setAge(int someAge){
		this.Age = someAge;
	}
	public void setSurname(String someSurname){
		this.Surname = someSurname;
	}
	public String getSurname(){
		return this.Surname;
	}
	public Gender getGender(){
		return this.Gender;
	}
	@Override
	public String toString(){
		return Name + " " + Surname + " " + Age + " " + DateOfBirth + " " + Gender.toString();
	}
}
